// 标签位置列表
export const markerWorldPositons = [
  {'x': 1884.3826998758532, 'y': 1475.0580689825567, 'z': -3.0205068588256836},
  {'x': 1892.2983425746988, 'y': 1470.3722423275094, 'z': -3.020534038543701},
  {'x': 1883.323486328125, 'y': 1455.2148284714876, 'z': -3.4064820845032},
  {'x': 1880.760092907586, 'y': 1457.989579746559, 'z': -3.0205341734412094},
  {'x': 1891.9235378073793, 'y': 1458.5222146198296, 'z': -3.0764206622220236},
  {'x': 1867.852998913893, 'y': 1470.9737538998975, 'z': -3.0204735810211543},
  {'x': 1867.604954973038, 'y': 1466.3705796955762, 'z': -3.020522542191191},
  {'x': 1870.9520485618546, 'y': 1461.1085566926695, 'z': -3.881410261738481},
  {'x': 1872.0875958867682, 'y': 1452.358642578125, 'z': -4.7429165167695375},
  {'x': 1879.6586762228633, 'y': 1451.510652813578, 'z': -6.369030052640775},
  {'x': 1884.8690511749244, 'y': 1449.0814853333354, 'z': -6.368996042977902},
  {'x': 1890.796236076864, 'y': 1456.0372320740842, 'z': -6.369142532348634},
  {'x': 1867.6227578576331, 'y': 1454.902956930701, 'z': -3.020536427844157},
  {'x': 1867.575010527969, 'y': 1449.0281327289288, 'z': -3.0205435641504366},
  {'x': 1871.737735110377, 'y': 1449.8391508288214, 'z': -6.369033336639404},
  {'x': 1884.6933590661681, 'y': 1453.229688009079, 'z': -6.368992496530155},
  {'x': 1885.8044759242955, 'y': 1473.9510777282253, 'z': -6.369142532348636},
  {'x': 1876.543599515271, 'y': 1461.5086669921875, 'z': -3.2780672617507887},
  {'x': 1889.3927368322848, 'y': 1472.5989713734944, 'z': -6.369142532348633},
  {'x': 1877.8213146942064, 'y': 1473.2271150987922, 'z': -6.169007116916128},
  {'x': 1891.9234619140627, 'y': 1446.9592390401447, 'z': -5.250190332564792}
]
// 工序列表
export const processList = [
  { process_name: '地下室外墙', process_id: 1, conditions: [{ floor: 'B2F建筑面（5.550）' }] },
  { process_name: '顶板基层处理', process_id: 2, conditions: [{ family: '基本墙' }] },
  { process_name: '现场浇注楼梯', process_id: 3, conditions: [{ family: '现场浇注楼梯' }] }
]

export const stateIcon = {
  dpd: require('@/assets/icons/bim/dpd.png'),
  dzg: require('@/assets/icons/bim/dzg.png'),
  yys: require('@/assets/icons/bim/yys.png'),
  yzg: require('@/assets/icons/bim/yzg.png')
}

// 状态列表
export const stateList = [
  { name: '待派单', color: '#ff8c00', id: 4, icon: 'dpd' },
  { name: '待整改', color: '#ff0000', id: 1, icon: 'dzg' },
  { name: '已整改', color: '#008000', id: 2, icon: 'yzg' },
  { name: '已验收', color: '#7abb46', id: 3, icon: 'yys' }
]

// 问题信息列表
export const infos = [
  { process: '止水钢板', state: '待派单', handler: '项目项目', time: '2022-07-01' },
  { process: '穿墙管道', state: '已验收', handler: '合诚检测', time: '2022-07-08' },
  { process: '后浇带、施工缝', state: '已整改', handler: '厦门项目', time: '2022-07-22' },
  { process: '地下室外墙', state: '已验收', handler: '合诚检测', time: '2022-08-01' },
  { process: '止水钢板', state: '待派单', handler: '项目项目', time: '2022-07-01' },
  { process: '穿墙管道', state: '已验收', handler: '合诚检测', time: '2022-07-08' },
  { process: '后浇带、施工缝', state: '已整改', handler: '厦门项目', time: '2022-07-22' },
  { process: '地下室外墙', state: '已验收', handler: '合诚检测', time: '2022-08-01' },
  { process: '防水卷材施工', state: '待整改', handler: '', time: '' }
]

// 模型状态列表
export const modelStateList = [{'state': '{"state":{"10000790815545":{"isolateAction":null,"actions":[],"sceneState":0,"version":"1.0"},"ExtrudeBodyManager":{"isolateAction":null,"actions":[],"sceneState":0,"version":"1.0"}},"camera":{"name":"persp","position":{"x":1871.6119718131724,"y":1446.1114738492704,"z":7.407214260582733},"target":{"x":1919.8090577103198,"y":1494.3087367838746,"z":-40.789694598457665},"up":{"x":0,"y":-0.0000036732024345150024,"z":0.999999999993254},"near":1.8063986628736262,"far":43.986062141051384,"zoom":3.246220630448603,"version":1,"fov":45,"aspect":0.634180790960452,"coordinateSystem":"world"},"selection":[],"axisGrid":{"fileInfos":[],"gridLineColor":{"red":51,"green":51,"blue":51,"alpha":1},"gridBubbleColor":{"red":0,"green":0,"blue":0,"alpha":1},"bIsBringToFront":false,"bIsEnableHover":true}}'}, {'state': '{"state":{"10000790815545":{"isolateAction":null,"actions":[],"sceneState":0,"version":"1.0"},"ExtrudeBodyManager":{"isolateAction":null,"actions":[],"sceneState":0,"version":"1.0"}},"camera":{"name":"persp","position":{"x":1877.9726882426298,"y":1465.6358181529654,"z":23.59009302481361},"target":{"x":1878.9943047652778,"y":1469.4667117098925,"z":-59.79550417978275},"up":{"x":-0.2574017060593138,"y":-0.9651366212568433,"z":-0.0474938314592449},"near":25.11667805178303,"far":42.024760192759395,"zoom":3.246220630448603,"version":1,"fov":45,"aspect":0.634180790960452,"coordinateSystem":"world"},"selection":[],"axisGrid":{"fileInfos":[],"gridLineColor":{"red":51,"green":51,"blue":51,"alpha":1},"gridBubbleColor":{"red":0,"green":0,"blue":0,"alpha":1},"bIsBringToFront":false,"bIsEnableHover":true}}'}, {'state': '{"state":{"10000790815545":{"isolateAction":null,"actions":[],"sceneState":0,"version":"1.0"},"ExtrudeBodyManager":{"isolateAction":null,"actions":[],"sceneState":0,"version":"1.0"}},"camera":{"name":"persp","position":{"x":1878.037567189702,"y":1448.1429178778244,"z":2.538161046295071},"target":{"x":1897.8949502425362,"y":1513.3474085473722,"z":-45.65868534170962},"up":{"x":0.16819985136723348,"y":0.5523032051564227,"z":0.816498609658328},"near":0.0032146377441429723,"far":36.921764419130525,"zoom":5.403723161948233,"version":1,"fov":45,"aspect":0.634180790960452,"coordinateSystem":"world"},"selection":[],"axisGrid":{"fileInfos":[],"gridLineColor":{"red":51,"green":51,"blue":51,"alpha":1},"gridBubbleColor":{"red":0,"green":0,"blue":0,"alpha":1},"bIsBringToFront":false,"bIsEnableHover":true}}'}, {'state': '{"state":{"10000790815545":{"isolateAction":null,"actions":[],"sceneState":0,"version":"1.0"},"ExtrudeBodyManager":{"isolateAction":null,"actions":[],"sceneState":0,"version":"1.0"}},"camera":{"name":"persp","position":{"x":1873.9393800502714,"y":1457.4361823228178,"z":6.246118823022807},"target":{"x":1893.7967631031058,"y":1522.6406729923656,"z":-41.95072756498188},"up":{"x":0.1681998513672373,"y":0.5523032051564353,"z":0.8164986096583189},"near":0.00321463774413188,"far":32.77858936192276,"zoom":7.010591865705547,"version":1,"fov":45,"aspect":0.634180790960452,"coordinateSystem":"world"},"selection":[],"axisGrid":{"fileInfos":[],"gridLineColor":{"red":51,"green":51,"blue":51,"alpha":1},"gridBubbleColor":{"red":0,"green":0,"blue":0,"alpha":1},"bIsBringToFront":false,"bIsEnableHover":true}}'}, {'state': '{"state":{"10000790815545":{"isolateAction":null,"actions":[],"sceneState":0,"version":"1.0"},"ExtrudeBodyManager":{"isolateAction":null,"actions":[],"sceneState":0,"version":"1.0"}},"camera":{"name":"persp","position":{"x":1878.5197885274201,"y":1452.6940216862426,"z":1.7177054584883031},"target":{"x":1898.3771715802543,"y":1517.8985123557904,"z":-46.47914092951638},"up":{"x":0.16819985136657928,"y":0.5523032051613477,"z":0.8164986096551315},"near":0.00321463774413188,"far":32.77858936192277,"zoom":7.010591865705547,"version":1,"fov":45,"aspect":0.634180790960452,"coordinateSystem":"world"},"selection":[],"axisGrid":{"fileInfos":[],"gridLineColor":{"red":51,"green":51,"blue":51,"alpha":1},"gridBubbleColor":{"red":0,"green":0,"blue":0,"alpha":1},"bIsBringToFront":false,"bIsEnableHover":true}}'}, {'state': '{"state":{"10000790815545":{"isolateAction":null,"actions":[],"sceneState":0,"version":"1.0"},"ExtrudeBodyManager":{"isolateAction":null,"actions":[],"sceneState":0,"version":"1.0"}},"camera":{"name":"persp","position":{"x":1874.3796785654292,"y":1456.5216248481988,"z":-1.1061737053798684},"target":{"x":1930.0920327245663,"y":1417.2528348511814,"z":-49.30340384517226},"up":{"x":0.471905571049438,"y":-0.3326266082850573,"z":0.8164953591253796},"near":0.003214637744136856,"far":28.136528629589822,"zoom":6.273890830089745,"version":1,"fov":45,"aspect":0.634180790960452,"coordinateSystem":"world"},"selection":[],"axisGrid":{"fileInfos":[],"gridLineColor":{"red":51,"green":51,"blue":51,"alpha":1},"gridBubbleColor":{"red":0,"green":0,"blue":0,"alpha":1},"bIsBringToFront":false,"bIsEnableHover":true}}'}]

// 问题详情
export const detail = {
  code: '厦门海玥和鸣1#楼1#屋面层',
  bench: '电梯机房',
  position: '敷设排列不整齐有交叉',
  height: '1-2梯 未标明线路',
  level: '施工缺陷',
  checkLevel: '一般',
  imageCode: '田博',
  standard: '【承查】供配电专业/布线/桥架/敷设排列整齐无交',
  assessLevel: '厦门金智惠电梯有限公司',
  register: '徐建福',
  date: '田博',
  inspector: '2023-02-12',
  remark: '已整改'
}

// 工序验收详情
export const scheduleDetail = [{
  code: '厦门海玥和鸣1#楼',
  bench: '电梯机房',
  floor: '',
  position: '敷设排列不整齐有交叉',
  height: '1-2梯 未标明线路',
  level: '施工缺陷',
  checkLevel: '一般',
  imageCode: '田博',
  standard: '布线/桥架/敷设排列整齐无交',
  assessLevel: '厦门金智惠电梯有限公司',
  register: '徐建福',
  date: '田博',
  inspector: '2023-02-12',
  remark: '已整改'
}, {
  code: '厦门海玥和鸣1#楼',
  bench: '幕墙',
  floor: '',
  position: '箍筋的数量满足设计要求',
  height: '箍筋的数量不正确',
  level: '施工缺陷',
  checkLevel: '一般',
  imageCode: '田博',
  standard: '箍筋的数量满足设计要求',
  assessLevel: '厦门金智惠电梯有限公司',
  register: '徐建福',
  date: '田博',
  inspector: '2023-02-12',
  remark: '已整改'
}]

// 模型viewTokens 列表
export const viewTokens = ['4b50a60e0178409bb92edfef33f7007d', 'd1af02a985ae4d0f8036b74feedcaf42', 'b860989437d540ae848c3cf45923b564']

// 重新获取viewToken 地址列表
export const viewTokenUrl = ['https://bimface.com/user-console/service/project-list?appKey=iZ1YmrdmHhbCUgEFQ3GgViRmTgnqezUQ',
  'https://bimface.com/developer-jsdemo#1037', 'https://bimface.com/developer-jsdemo#1027']

// 楼层模型viewTokens 列表
export const floorViewTokens = ['b860989437d540ae848c3cf45923b564']
// 重新获取 楼层viewToken 地址列表
export const viewTokenFloorUrl = ['https://bimface.com/developer-jsdemo#1027']

// 相机状态 floor
export const camera = {'name': 'persp', 'position': {'x': -19.606316298689045, 'y': -43.08613223109428, 'z': 43.49481560293228}, 'target': {'x': 185.6213342107638, 'y': 162.14204512812725, 'z': -99.93534123111299}, 'up': {'x': 0.3132766660933835, 'y': 0.31327337305627334, 'z': 0.8965029415542148}, 'near': 0.025030001592684308, 'far': 210.44886171078494, 'zoom': 2.7428806900598297, 'version': 1, 'fov': 45, 'aspect': 2.13200498132005, 'coordinateSystem': 'world'}

// 色值混合 计算两个色值
export const colourBlend = function(c1, c2, ratio) {
  ratio = Math.max(Math.min(Number(ratio), 1), 0)
  const r1 = parseInt(c1.substring(1, 3), 16)
  const g1 = parseInt(c1.substring(3, 5), 16)
  const b1 = parseInt(c1.substring(5, 7), 16)
  const r2 = parseInt(c2.substring(1, 3), 16)
  const g2 = parseInt(c2.substring(3, 5), 16)
  const b2 = parseInt(c2.substring(5, 7), 16)
  let r = Math.round(r1 * (1 - ratio) + r2 * ratio)
  let g = Math.round(g1 * (1 - ratio) + g2 * ratio)
  let b = Math.round(b1 * (1 - ratio) + b2 * ratio)
  r = ('0' + (r || 0).toString(16)).slice(-2)
  g = ('0' + (g || 0).toString(16)).slice(-2)
  b = ('0' + (b || 0).toString(16)).slice(-2)
  return '#' + r + g + b
}

// 工序数据
export const scheduleList = [
  {name: '钢筋工程', checkTableId: 'x9oAABeE7QZC0JIj', unitType: 1, number: '30103', color: '#57c2b3', bgColor: 'rgba(87, 194, 179, 0.5)', value: 6, floor: 'F6'},
  {name: '混凝土工程', checkTableId: 'x9oAABeE7VpC0JIj', unitType: 1, number: '30101', color: '#82c0ff', bgColor: 'rgba(130,192,255, 0.5)', value: 5, floor: 'F5'},
  {name: '混凝土反坎', checkTableId: 'x9oAABeE7YlC0JIj', unitType: 1, number: '30301', color: '#e6d7d3', bgColor: 'rgba(230,235,211,0.5)', value: 4, floor: 'F4'},
  {name: '抹灰', checkTableId: 'x9oAABeE7fRC0JIj', unitType: 2, number: '30103', color: '#658f9d', bgColor: 'rgba(101,143,157,0.5)', value: 3, floor: 'F3'}
]

// 工序进度状态
export const scheduleProcessState = [
  {'conditions': [{'levelName': 'F1'}, {'levelName': 'F2'}, {'levelName': 'F3'}, {'levelName': 'F4'}, {'levelName': 'F5'}, {'levelName': 'F6'}], 'color': '#57c2b3'},
  {'conditions': [{'levelName': 'F1'}, {'levelName': 'F2'}, {'levelName': 'F3'}, {'levelName': 'F4'}, {'levelName': 'F5'}], 'color': '#82c0ff'},
  {'conditions': [{'levelName': 'F1'}, {'levelName': 'F2'}, {'levelName': 'F3'}, {'levelName': 'F4'}], 'color': '#e6d7d3'},
  {'conditions': [{'levelName': 'F1'}, {'levelName': 'F2'}, {'levelName': 'F3'}], 'color': '#658f9d'}]

// 进度日期
export const dateList = [
  '2023-05-12', '2023-05-14', '2023-05-16', '2023-05-19', '2023-05-23', '2023-05-27',
  '2023-05-30', '2023-06-03', '2023-06-06', '2023-06-09', '2023-06-14', '2023-06-16',
  '2023-06-19', '2023-06-23', '2023-06-27', '2023-06-30', '2023-07-03', '2023-07-06',
  '2023-07-09', '2023-07-14']
